package org.jeecg.modules.compilation.service;

import org.jeecg.common.api.vo.Result;
import org.jeecg.modules.compilation.dto.FavouriteSearchDTO;
import org.jeecg.modules.compilation.entity.CiDoc;
import org.jeecg.modules.compilation.entity.CiFavorite;
import com.baomidou.mybatisplus.extension.service.IService;

import java.io.IOException;
import java.util.List;

/**
 * @Description: ci_favorite
 * @Author: jeecg-boot
 * @Date:   2024-03-15
 * @Version: V1.0
 */
public interface ICiFavoriteService extends IService<CiFavorite> {

    /**
     * 获取收藏夹数据
     * @return
     */
    List<CiFavorite> getFavoriteList();

    /**
     * 获取文件数据
     * @return
     */
    CiDoc getDoc(String documentSn);
    String updateFavorite(CiFavorite ciFavorite);

    List<CiFavorite> queryList(FavouriteSearchDTO favouriteSearchDTO) throws IOException;
    /*
     * 数据库和索引库的同步
     * */
    void deleteById(Long id);

    /*
     * 数据库和索引库的同步
     * */
    void insertById(Long id) throws IOException;

    void deleteBatch(List<String> list);
//    //取消收藏
//    void omit(String docSn);
}
